﻿using System;
using System.Collections.Generic;
using System.Text;

namespace Eagle.Web.TagFactory
{
    /// <summary>
    /// 图片地址生成类
    /// </summary>
    public class Img
    {
        /// <summary>
        /// 生成图片标签
        /// </summary>
        /// <param name="id">图片id</param>
        /// <param name="src">图片地址</param>
        /// <param name="className">应用的类名</param>
        /// <param name="properties">其他属性</param>
        /// <returns></returns>
        public static string Create(string id,string src,string className,string properties)
        {
            return "<img id=\"" + id + "\" src=\"" + src + "\"  class=\"" + className + "\" " + properties + " />";
        }

        /// <summary>
        /// 生成图片标签
        /// </summary>
        /// <param name="id">图片id</param>
        /// <param name="src">图片地址</param>
        /// <param name="className">应用的类名</param>
        /// <returns></returns>
        public static string Create(string id, string src, string className)
        {
            return Create(id, src, className, "");
        }
    }
}
